package com.syg.case04;

import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.stereotype.Component;

@Aspect
@Component
public class AspectCase04 {

    @Pointcut("execution(* com.syg.case04.ACase04.*(..))")
    public void aspect() {
    }

    @Before("aspect()")
    public void before() {
        System.out.println("方法A中,调用方法B,方法B不会被拦截,此方法调用1次");
    }
}
